
package keter.domain;

import javax.persistence.Entity;
import javax.persistence.Table;
import javax.persistence.UniqueConstraint;

import keter.domain.base.BaseEntity;

import org.hibernate.annotations.Cache;
import org.hibernate.annotations.CacheConcurrencyStrategy;
import org.hibernate.validator.constraints.NotEmpty;

/**
 * <p>Class       : keter.domain.CodeList
 * <p>Descdription: 类功能描述
 * @author  顾力行-gulx@neusoft.com
 * @version 1.0.0
 */
@Entity
@Table(name="codelist",
 uniqueConstraints = @UniqueConstraint(columnNames = { "codeKind","codeValue" }))
@Cache(usage = CacheConcurrencyStrategy.READ_WRITE)
public class CodeList extends BaseEntity{
	@NotEmpty
	private String codeValue;
	@NotEmpty
	private String codeName;
	@NotEmpty
	private String codeKind;
//	@NotEmpty
	private String kindName;
	
	public String getCodeValue() {
		return codeValue;
	}
	public void setCodeValue(String codeValue) {
		this.codeValue = codeValue;
	}
	
//	@Column(unique = true)
	public String getCodeKind() {
		return codeKind;
	}
	public void setCodeKind(String codeKind) {
		this.codeKind = codeKind;
	}
	public String getCodeName() {
		return codeName;
	}
	public void setCodeName(String codeName) {
		this.codeName = codeName.toUpperCase();
	}
	public String getKindName() {
		return kindName;
	}
	public void setKindName(String kindName) {
		this.kindName = kindName.toUpperCase();
	}
}
